import React from 'react';
import { useParams } from 'react-router-dom';
import HotMovie from './HotMovie';
import UpcomingMovie from './UpcomingMovie';

const MovieListByType = ({ type }) => {
    if (type === 'upcoming') {
        return <UpcomingMovie />;
    } else if (type === 'now-playing') {
        return <HotMovie />;
    }

    return <div>未找到对应的电影类型</div>;
};

export default MovieListByType;